package hmvictor.jpql.nodes;

import java.io.File;
import javax.swing.Action;

/**
 *
 * @author Victor
 */
public class JpaJarNode extends JarNode {

    public JpaJarNode(FileChildrenFactory factory) {
        super(factory);
    }

    public JpaJarNode(File jarFile) {
        super(jarFile);
    }

    @Override
    public Action[] getActions(boolean context) {
        File file = getLookup().lookup(File.class);
        if (file == null) {
            return new Action[]{new AddJpaJarAction()};
        } else {
            return new Action[]{new RemoveJpaJarAction(this)};
        }
    }

}
